﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace GFluentCode.Entity
{
    /// <summary>
    /// 列属性
    /// </summary>
    [AttributeUsage(AttributeTargets.Property, Inherited = true)]
    public class GFluentColumn:Attribute
    {
        /// <summary>
        /// 列名
        /// </summary>
        public string ColumnName { get; set; }

        /// <summary>
        /// 列特性
        /// </summary>
        public EnColumnType ColumnType { get; set; } = EnColumnType.Normal;

        private GFluentColumn() { }

        public GFluentColumn(string columnName)
        {
            ColumnName = columnName;
        }

        public GFluentColumn(string columnName,EnColumnType colType)
        {
            ColumnName = columnName;
            ColumnType = colType;
        }

        public GFluentColumn(EnColumnType colType)
        {
            ColumnType = colType;
        }

    }
}
